package com.google.code.lf.gfm.ui;

import org.eclipse.ui.IPageLayout;
import org.eclipse.ui.IPerspectiveFactory;
import org.eclipse.ui.console.IConsoleConstants;

public class Perspective implements IPerspectiveFactory {

	public void createInitialLayout(final IPageLayout layout) {
		final String editorArea = layout.getEditorArea();
		layout.setEditorAreaVisible(true);
		layout.setFixed(false);
		//TODO Raccourcis à gérer
		layout.addPerspectiveShortcut(ApplicationWorkbenchAdvisor.PERSPECTIVE_ID);
		layout.addShowViewShortcut(OptionsView.ID);
		layout.addShowViewShortcut(IConsoleConstants.ID_CONSOLE_VIEW);
		layout.addView(OptionsView.ID, IPageLayout.TOP, 0.25f, editorArea);
		//TODO Gérer éditeur de fichier de conf
		layout.addView(IConsoleConstants.ID_CONSOLE_VIEW, IPageLayout.BOTTOM, 0.66f/*IPageLayout.DEFAULT_VIEW_RATIO*/, editorArea);
	}

}
